<!DOCTYPE html>
<html lang="en">
<head>
    <title>{$username}的首页</title>
    <link href="/static/index/css/font-awesome.min.css" rel="stylesheet" type="text/css" media="all" /><!-- fontawesome -->
    <link href="/static/index/css/bootstrap.min.css" rel="stylesheet" type="text/css" media="all" /><!-- Bootstrap stylesheet -->
    <link href="/static/index/css/style.css" rel="stylesheet" type="text/css" media="all" />
    <link rel="stylesheet" href="/static/index/reset.css" type="text/css">
    <link rel="stylesheet" href="/static/index/css/flexslider.css" type="text/css" media="screen" property="" />
    <!-- stylesheet -->
    <!-- meta tags -->
    <meta name="viewport" content="width=device-width, initial-scale=1">
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
    <meta name="keywords" content="" />
    <script type="application/x-javascript"> addEventListener("load", function() { setTimeout(hideURLbar, 0); }, false); function hideURLbar(){ window.scrollTo(0,1); } </script>
    <!-- //meta tags -->
    <!--fonts-->
    <link href="http://fonts.googleapis.com/css?family=Roboto+Condensed:300,300i,400,400i,700,700i&subset=cyrillic,cyrillic-ext,greek,greek-ext,latin-ext,vietnamese" rel="stylesheet">
    <link href="http://fonts.googleapis.com/css?family=Open+Sans" rel="stylesheet">
    <!--//fonts-->
    <script type="text/javascript" src="/static/index/js/jquery-2.1.4.min.js"></script>
    <script src="/static/index/js/main.js"></script>
    <link rel="stylesheet" type="text/css" href="/static/index/css/toastr.min.css" />
    <link href="/static/index/js/layui/css/layui.css" rel="stylesheet">


    <!-- Required-js -->
    <!-- start-smoth-scrolling -->
    <script type="text/javascript" src="/static/index/js/move-top.js"></script>
    <script type="text/javascript" src="/static/index/js/easing.js"></script>
    <script type="text/javascript">
        jQuery(document).ready(function($) {
            $(".scroll").click(function(event){
                event.preventDefault();
                $('html,body').animate({scrollTop:$(this.hash).offset().top},1000);
            });
        });
    </script>

    <!-- start-smoth-scrolling -->

    <!-- scriptfor smooth drop down-nav -->
    <script>
        $(document).ready(function(){
            $(".dropdown").hover(
                function() {
                    $('.dropdown-menu', this).stop( true, true ).slideDown("fast");
                    $(this).toggleClass('open');
                },
                function() {
                    $('.dropdown-menu', this).stop( true, true ).slideUp("fast");
                    $(this).toggleClass('open');
                }
            );
        });
    </script>

    <!-- //script for smooth drop down-nav -->
</head>
<body class="bk">
<style>
    .ziliao{
        font-size: 13px;
        margin-left: 530px;
    }

</style>
<div class="collapse navbar-collapse" id="my-navbar-collapse">

    <ul class="nav navbar-nav navbar-right">
        <a href="javascript:history.back(-1)" style="margin-right: 1200px;">返回上一页</a>
        <li>
            <a href="#" style="color: black" class="mingzi">{$username}</a>
        </li>
        <li class="dropdown">
            <a href="#" class="dropdown-toggle" data-toggle="dropdown">
                安全中心<b class="caret"></b>
            </a>
            <ul class="dropdown-menu">
                <a href="{:url('index/login/loginOut')}" class="roll-nav roll-right J_tabExit tuichu" style="width: 50">
                    &nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp <i class="fa fa fa-sign-out"></i>退出</a><br>
                <a href="{:url('/editpass')}">&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp更改密码</a>
            </ul>
        </li>
    </ul>
</div>
<!-- header -->
<header>
    <div class="w3layouts-top-strip">
        <div class="container">
            <div class="logo">
                <a href="{:url('/edit')}"><img src="{$photo}"  class="img-circle" width="100"></a>
                <h3><a href="{:url('/edit')}">{$username}</a></h3>
            </div>
        </div>
    </div>
    <!-- navigation -->
    <nav class="navbar  navbar-fixed-top" role="navigation" style="background: #e0620d ;padding-top: 3px;height:50px;">
        <div class="container-fluid" style="background: #fff;">
            <div class="navbar-header ">

                <a class="navbar-brand " href="{:url('/index/index/index')}">返回首页</a>


                <button type="button" class="navbar-toggle" data-toggle="collapse"
                        data-target="#my-navbar-collapse">
                    <span class="sr-only">切换导航</span>
                    <span class="icon-bar"></span>
                    <span class="icon-bar"></span>
                    <span class="icon-bar"></span>
                </button>
            </div>
            <form class="navbar-form navbar-left" role="search" action="{:url('/wbSearch')}" method="post">
                <div class="form-group">
                    <input type="text" class="form-control" name="Search" placeholder="微博找人">
                    <button class="glyphicon glyphicon-search btn_search btn btn-default" ></button>
                    <!--  <button type="submit" class="btn btn-default">提交</button> -->
                </div>

            </form>

            <div class="collapse navbar-collapse" id="my-navbar-collapse">

                <ul class="nav navbar-nav navbar-right" >
                    <li style="margin-right: 20px">
                        <a href="{:url('index/dologin')}" style="color: black;padding: 0px!important;color: #ccc;" class="mingzi">个人首页</a>
                    </li>
                    <li ><img src="{$photo}" width="30px" style="border-radius: 50%">
                        <a href="{:url('index/cuser/index')}" style="color: black;padding: 0px!important;" class="mingzi">{$username}</a>
                    </li>

                    <li class="dropdown">
                        <a href="#" class="dropdown-toggle" data-toggle="dropdown">
                            安全中心<b class="caret"></b>
                        </a>
                        <ul class="dropdown-menu">
                            <a href="{:url('index/login/loginOut')}" class="roll-nav roll-right J_tabExit tuichu" >

                                &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <i class="fa fa fa-sign-out"></i>
                                退出</a><br>

                            <a href="{:url('/editpass')}">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;更改密码</a>

                        </ul>
                    </li>
                </ul>
            </div>
        </div>
        <hr style="margin: 0;padding: 0;color:#222;width: 100%">
    </nav>

    <!-- //navigation -->
</header>

<div class="breadcrumbs">
    <div class="container">
        <div class="row readcrumb breadcrumb1 animated wow fs20 cf" data-wow-delay=".5s">
            <div class="col-md-4"></div>
            <div class="col-md-2"><a href="{:url('/cuser')}" class="cf">主页</a></div>
            <div class="col-md-1"></div>
            <div class="col-md-1"><a href="cphoto.html" class="cf">相册</a></div>
            <div class="col-md-1"></div>
        </div>


    </div>
</div>
<!-- //breadcrumbs -->
{block name="buser"}
<div class="container">
    <div class="banner-btm-agile">

        <!-- //btm-wthree-left -->
        <div class="col-md-9 btm-wthree-left">

            <div class="agileits_heading_section">
                <h3 class="wthree_head">我曾经发过的微博</h3>
                <p class="agileinfo_para">回首过去,展望未来</p>
            </div>
            <!-- wthree-top -->
            <div class="wthree-top-6">

            </div>
            <!-- //wthree-top -->
            <!-- wthree-top-1 -->

            {volist name="message" id="v"}
            {empty name="v['src_id']"}
            <div class="col-md-12" style="border: 1px solid #FFAC3A;width: 100% ;padding: 20px;">
                <div class="col-md-12">
                    <div class="col-md-1">
                        <div class="comments-grid-left">
                            <img src="{$photo}" style="width: 48px;height: 48px;"/>
                        </div>
                    </div>
                    <div class="col-md-11" style="margin-bottom: 10px;">
                        <br>
                        <h5 style="margin-left:50px;font-size: 16px;color:#FFAC3A;">{$username}</h5>
                        <p style="font-size: 12px;">{$v['time']}</p>
                        <br>
                        <p>{:replace_weibo($v['content'])}</p>
                        <!--</div>-->

                        <!--<br>-->
                        <ul class="slides col-md-4" style="margin-top: 10px;">

                            <li>
                                {empty name="$v['path']"}
                                {else /}
                                <div class="w3agile_special_deals_grid_left_grid">
                                    <a href="{:url('index/show/index',['id'=>$v['id']])}"><img src="{$v['path']}" class="img-responsive" width="780" style="height: 200px!important"/></a>
                                </div>
                                {/empty}
                            </li>

                        </ul>
                    </div>

                </div>
                <div class="col-md-1"></div>
                <div class="col-md-11">
                    <ul class="col-md-6">
                        <li data-toggle="modal" data-target="#exampleModal" style="float: left; margin-left:10px;"><a><i
                                class="fa fa-share turn-btn" aria-hidden="true" data-id="{$v['id']}"> &nbsp;
                            {$v['transpondnum']}</i> </a></li>
                        <li style="float: left; margin-left:10px;"><a><i class="fa fa-thumbs-up agree-btn"
                                                                         aria-hidden="true" data-id="{$v['id']}"> &nbsp;
                            {$v['agreenum']}</i></a></li>
                        <li data-toggle="modal" data-target="#exampleModal" style="float: left; margin-left:10px;"><a><i
                                class="fa fa-comment com-btn" aria-hidden="true" data-id="{$v['id']}"> &nbsp;
                            {$v['commentnum']}</i></a></li>

                        <li style="float: left; margin-left:10px;">
                            <button type="button" onclick="delWeibo(this)" style="border: #fff;background: #fff;" value="{$v['id']}" data-id="{$v['id']}" class="del-btn"><i class="fa fa-trash" aria-hidden="true"></i></button>
                        </li>
                    </ul>
                    <div class="col-md-6">
                        <a class="agileits w3layouts" href="{:url('index/show/index',['id'=>$v['id']])}">查看评论 <span
                                class="glyphicon agileits w3layouts glyphicon-arrow-right"
                                aria-hidden="true"></span></a>
                    </div>
                </div>
            </div>

            <div class="clearfix"></div>
            <br><br>
            {else /}
            <!--<div class="col-md-9 btm-wthree-left">-->
            <div class="col-md-12" style="border: 1px solid #FFAC3A;width: 100% ;padding: 20px;">
                <div class="col-md-12">
                    <div class="col-md-4 w3agile-left">
                        <div class="comments-grid-left">
                            <img src="{$v['photo']}" style="width: 48px;height: 48px;"/>
                        </div>
                        <h5 style="margin-left:110px;font-size: 16px;color:#FFAC3A;">{$v['username']}</h5>

                        <p style="font-size: 12px;margin-left: 60px;">{$v['time']}</p>
                        <p style="margin-left: 100px">转发微博</p>

                    </div>
                    <div class="col-md-8 w3agile-right" style="margin: 0 auto;">
                        <p>{:replace_weibo($v['content'])}</p>
                    </div>
                    <ul class="slides col-md-4" style="margin-top: 10px;">
                        <li>
                            {empty name="$v['path']"}
                            {else /}
                            <div class="w3agile_special_deals_grid_left_grid">
                                <a href="{:url('index/show/index',['id'=>$v['id']])}">
                                    <img src="{$v['path']}" class="img-responsive"  width="780" style="height: 200px!important"/>
                                </a>
                            </div>
                            {/empty}
                        </li>
                    </ul>
                </div>
                <div class="col-md-12" style="background: #eee">
                    <div class="col-md-1" >
                        <div class="comments-grid-left">
                            <a href="{:url('/tourists')}?id={$v['old']['uid']}">
                                <img src="{$v['old']['photo']}" style="width: 48px;height: 48px;"/>
                            </a>
                        </div>
                    </div>
                    <div class="col-md-11" >
                        <br>
                            <a href="{:url('/tourists')}?id={$v['old']['uid']}">

                        <h5 style="margin-left:50px;font-size: 16px;">{$v['old']['username']}</h5></a>
                        <p style="font-size: 12px;">{$v['time']}</p>
                        <br>
                        <p>{:replace_weibo($v['old']['content'])}</p>
                        <!--</div>-->

                        <!--<br>-->
                        <ul class="slides col-md-4" style="margin-top: 10px;">

                            <li>
                                <div class="w3agile_special_deals_grid_left_grid">
                                {empty name="v['old']['path']"}
                                {else /}

                                <a href="{:url('index/show/index',['id'=>$v['old']['id']])}"><img src="{$v['old']['path']['path']}" class="img-responsive" alt="" width="780" style="height: 200px!important"/></a>
                                {/empty}
                            </div>
                            </li>
                        </ul>
                    </div>
                </div>
                <div class="col-md-12"  style="background: #eee">
                    <div class="col-md-1">
                    </div>
                    <div class="col-md-11">
                        <ul class="col-md-6">
                            <li data-toggle="modal" data-target="#exampleModal" style="float: left; margin-left:10px;"><a><i
                                    class="fa fa-share turn-bt" aria-hidden="true" data-id="{$v['old']['id']}"> &nbsp;
                                {$v['transpondnum']}</i> </a></li>
                            <li style="float: left; margin-left:10px;"><a><i class="fa fa-thumbs-up agree-btn"
                                                                             aria-hidden="true" data-id="{$v['id']}"> &nbsp;
                                {$v['agreenum']}</i></a></li>
                            <li data-toggle="modal" data-target="#exampleModal" style="float: left; margin-left:10px;"><a><i
                                    class="fa fa-comment com-bt" aria-hidden="true" data-id="{$v['id']}"> &nbsp;
                                {$v['commentnum']}</i></a></li>
                            <li style="float: left; margin-left:10px;">
                                <button type="button" onclick="delWeibo(this)" style="border: #fff;background: #fff;" value="{$v['id']}" data-id="{$v['id']}" class="del-btn"><i class="fa fa-trash" aria-hidden="true"></i></button>
                            </li>
                        </ul>
                        <div class="col-md-6">
                            <a class="agileits w3layouts" href="{:url('index/show/index',['id'=>$v['id']])}">查看评论 <span
                                    class="glyphicon agileits w3layouts glyphicon-arrow-right"
                                    aria-hidden="true"></span></a>
                        </div>
                    </div>
                </div>
            </div>
            <hr>
            <br>
            {/empty}
            {/volist}
            <br>
            <br>
        </div>

    </div>
        <!-- //btm-wthree-left -->
        <!-- btm-wthree-right -->
        <div class="col-md-3 w3agile_blog_left">
            <div class="wthreesearch">
                <form action="{:url('/wbSearch')}" method="post">
                    <input type="search" name="Search" placeholder="Search here" required="">
                    <button type="submit" class="btn btn-default search" aria-label="Left Align">
                        <i class="fa fa-search" aria-hidden="true"></i>
                    </button>

                </form>

            </div>

            <div class="w3ls_popular_posts">
                <h3>查看企业发起活动</h3>

                {volist name="at" id="v"}
                <div class="agileits_popular_posts_grid">
                    <div class="w3agile_special_deals_grid_left_grid">

                        <a href="{:url('/server')}?uid={$v['uid']}"><img src="{$v['thumbnail']}" class="img-responsive" alt="" style="height: 200px" /></a>
                    </div>
                    <h4><a href="{:url('/server')}?uid={$v['uid']}">{$v['title']}</a></h4>

                    <h5><i class="fa fa-calendar" aria-hidden="true"></i>FEB 15,2017</h5>
                </div>
                {/volist}
            </div>

            <div class="w3l_categories">
                <h3>微博认证</h3>
                <table class="table">
                    <tr>
                        <th>{$username}的微博《已认证》</th>
                    </tr>
                </table>
                <!--<ul class="list-group">-->
                <!--<li class="list-group-item">XXX的微博</li>-->
                <!--<li class="list-group-item">简介</li>-->
                <!--<li class="list-group-item">友情链接</li>-->
                <!--</ul>-->
            </div>

            <div class="w3l_tags">
                <h3>微关系</h3>
                <ul class="tag">
                    <h4>NI的关注</h4>
                    <li>
                        {volist name="attent" id="v"}

                        <div class=" col-md-4">
                            <div class="thumbnail" style="border: #fff;">
                                <img src="{$v['photo']}" class="img-circle">
                                <div class="caption">
                                    <p style="width: 70px;">{$v['username']}</p>
                                </div>
                            </div>
                        </div>
                        {/volist}
                    </li>
                    <h4>NI的粉丝</h4>
                    <li>
                        {volist name="fans" id="v"}
                        <div class=" col-md-4" >
                            <div class="thumbnail" style="border: #fff;">
                                <img src="{$v['photo']}" class="img-circle">
                                <div class="caption">
                                    <p style="width: 70px;">{$v['username']}</p>
                                </div>
                            </div>
                        </div>
                        {/volist}
                    </li>
                </ul>
            </div>
        </div>
        <!-- //btm-wthree-right -->
        <div class="clearfix"></div>
    </div>
</div>
{/block}
<!-- footer -->
<div class="footer-agile-info">
    <div class="container">
        <div class="col-md-4 w3layouts-footer">
            <h3>联系信息</h3>
            <p><span><i class="fa fa-map-marker" aria-hidden="true"></i></span>中华人民共和国上海市徐汇区</p>

            <p><span><i class="fa fa-envelope" aria-hidden="true"></i></span><a href="#">981246441@qq.com</a> </p>

            <p><span><i class="fa fa-envelope" aria-hidden="true"></i></span><a href="#">1551941489@qq.com</a> </p>

            <p><span><i class="fa fa-mobile" aria-hidden="true"></i></span>P: 03765759119 </p>
            <p><span><i class="fa fa-globe" aria-hidden="true"></i></span><a href="http://www.zhc1995.cn">W: www.zhc1995.cn</a></p>
        </div>
        <div class="col-md-4 wthree-footer">
            <h2>网站简介</h2>
            <p>本网站纯属娱乐,如作商业用途,请联系本人</p>
        </div>
        <div class="col-md-4 w3-agile">
            <h3>意见反馈</h3>
            <p>如果您有好的提议,前邮件联系作者</p>

        </div>
    </div>
</div>
<!-- footer -->

<!-- copyright -->
<div class="copyright">
    <div class="container">

        <div class="agileinfo">
            <p>版权 © 魔狗工作室保留一切版权魔狗工作室备案号:19001432</p>
        </div>
    </div>
</div>
<div class="modal fade" id="myModal" tabindex="-1" role="dialog" aria-labelledby="myModalLabel">
    <div class="modal-dialog" role="document">
        <div class="modal-content">
            <div class="modal-header">
                <button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">&times;</span></button>
                <h4 class="modal-title" id="myModalLabel">
                    已点赞
                </h4>
            </div>
            <div class="modal-footer">
                <button type="button" class="btn btn-danger" data-dismiss="modal">关闭</button>
            </div>
        </div>
    </div>
</div>


<div class="modal fade" id="exampleModal" tabindex="-1" role="dialog" aria-labelledby="exampleModalLabel">
    <div class="modal-dialog" role="document">
        <div class="modal-content">
            <div class="modal-header">
                <button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">&times;</span></button>
                <h4 class="modal-title" id="exampleModalLabel">转发</h4>
            </div>
            <div class="modal-body">
                <form>
                    <div class="form-group">
                        <label for="recipient-name" class="control-label">原微博</label>
                        <div class="username"></div>
                        <div class="form-control old" id="message-text" style="border: solid #ccc 1px;height: 50px;"></div>
                        <input type="text" name="mid" value="" class="mid" hidden>
                    </div>
                    <div class="form-group">
                        <label for="message-text" class="control-label ">你的意见</label>
                        <textarea class="form-control new" id="message-text"></textarea>
                    </div>
                </form>
            </div>
            <div class="modal-footer">
                <button type="button" class="btn btn-default clos" data-dismiss="modal">关闭</button>
                <button type="button" class="btn btn-primary turn">转发</button>
                <button type="button" class="btn btn-primary commen" style="display: none">评论</button>

            </div>
        </div>
    </div>
</div>
<!-- //copyright -->
<!-- here stars scrolling icon -->
<script src="/static/index/js/toastr.min.js"></script>

<script type="text/javascript">
    $(document).ready(function() {
        /*
            var defaults = {
            containerID: 'toTop', // fading element id
            containerHoverID: 'toTopHover', // fading element hover id
            scrollSpeed: 1200,
            easingType: 'linear'
            };
        */

        $().UItoTop({ easingType: 'easeOutQuart' });
        $('.jump').click(function () {
            var name = $(this).attr('data-name');
            // var name = 1111;
            console.log("{:url('/index/talk/name')}?name='"+name+"'");
            window.location.href="{:url('/index/talk/name')}?name='"+name+"'";
        });

        $('.turn-bt').click(function(){
            var content = $(this).parent().parent().parent().parent().parent().prev().children().next().children().next().next().next().next().html();
            var username = $(this).parent().parent().parent().parent().parent().prev().children().next().children().next().html();
            // console.log(username);
            var mid = $(this).attr('data-id');
            console.log(mid);
            $('.old').html(content);
            $('.mid').val(mid);
            $('.username').html(username + ' : ');
            $('.turn').show();
            $('.commen').hide();
            $('#exampleModalLabel').html('转发');
            $('.new').val(' ');
        });

        //点击转发形式微博的评论按钮
        $('.com-bt').click(function(){
            var content = $(this).parent().parent().parent().parent().parent().prev().children().next().children().next().next().next().next().html();
            var username = $(this).parent().parent().parent().parent().parent().prev().children().next().children().next().html();
            // console.log(username);
            var mid = $(this).attr('data-id');

            $('.old').html(content);
            $('.mid').val(mid);
            //改变转发按钮为评论按钮
            $('.turn').hide();
            $('.commen').show();
            $('.username').html(username + ' : ');
            $('.new').val(' ');
            $('#exampleModalLabel').html('评论');
        });



        //转发按钮
        $('.turn-btn').click(function () {
            var content = $(this).parent().parent().parent().parent().prev().prev().children().children().next().next().next().next().html();
            var username = $(this).parent().parent().parent().parent().prev().prev().children().children().next().html();
            var mid =$(this).attr('data-id');
            // console.log(mid);
            $('.old').html(content);
            $('.mid').val(mid);
            $('.username').html(username+' : ');
            $('.turn').show();
            $('.commen').hide();
            $('#exampleModalLabel').html('转发');
            $('.new').val(' ');

        });
        //点击转发
        $('.turn').click(function () {
            var oldContent = $('.old').val();
            var mid = $('.mid').val();
            var content = $('.new').val();

            $('.clos').click();
            // console.log(oldContent,mid,content);
            //执行ajax
            $.ajax({
                type: 'post',
                url: "/index/send/turn",
                contentType:'application/x-www-form-urlencoded;charset=utf-8',
                data:{src_id:mid,content:content},
                dataType: 'json',
                success: function (data) {
                    // console.log(data);
                    if (data) {

                        toastr.success('转发成功','牛皮!:');
                    } else {
                        toastr.success('未登录','抱歉!:');
                        window.location.href="{:url('login/index')}";
                    }
                },
                error: function () {
                    toastr.error('AJAX 执行错误!', '警告:');
                }
            });


        });

        //点击评论
        $('.com-btn').click(function () {
            var content = $(this).parent().parent().parent().parent().prev().prev().children().children().next().next().next().next().html();
            var username = $(this).parent().parent().parent().parent().prev().prev().children().children().next().html();
            var mid =$(this).attr('data-id');
            $('.old').html(content);
            $('.mid').val(mid);
            //改变转发按钮为评论按钮
            $('.turn').hide();
            $('.commen').show();
            $('.username').html(username+' : ');
            $('.new').val(' ');
            $('#exampleModalLabel').html('评论');
        })
        //点击评论按钮
        $('.commen').click(function () {
            var oldContent = $('.old').val();
            var mid = $('.mid').val();
            var content = $('.new').val();

            $('.clos').click();
            // console.log(oldContent,mid,content);
            //执行ajax
            $.ajax({
                type: 'post',
                url: "/index/content/content",
                contentType:'application/x-www-form-urlencoded;charset=utf-8',
                data:{mid:mid,content:content},
                dataType: 'json',
                success: function (data) {
                    // console.log(data);
                    if (data) {
                        $('.new').val('');
                        toastr.success('已评论','牛皮!:');
                    } else {
                        window.location.href="{:url('login/index')}";

                    }
                },
                error: function () {
                    toastr.error('AJAX 执行错误!', '警告:');
                }
            });
        });


    });

    var SCOPE = {
        'attent_url': '{:url(\'index/cuser/delWeibo\')}'
    }


   function delWeibo(obj) {
    // debugger;
    var id = $(obj).val();
    // alert(id);
    if (confirm('您确定要 [ 删除 ] 这条微博吗?')) {
        $.ajax({
            type: "get",
            data: {"id": id},
            dataType: "json",
            // url:SCOPE.attent_url,
            url: '{:url(\'index/buser/delWeibo\')}',
            success: function (data) {
                console.log("zslog 13.2 异步调用返回成功,result:" + data.id);
                parent.location.reload();
            },
            error: function (XMLHttpResponse, textStatus, errorThrown) {
                console.log("1 异步调用返回失败,XMLHttpResponse.readyState:" + XMLHttpResponse.readyState);

            }
        });
    }else {
        return false;
    }
}


    toastr.options = {
        closeButton: true,// 是否显示关闭按钮
        progressBar: true,// 实现显示计时条
        timeOut: "1000",  // 自动关闭时间
        positionClass: "toast-bottom-left" // 提示位置
        // toast-top-full-width 顶端，宽度铺满整个屏幕
        // toast-top-right  顶端右边
    };

    $(function () {
        // 触发点赞操作
        $('.agree-btn').click(function () {
            var mid = $(this).attr('data-id');
            // $(this).text('11111');
            res = $(this);

            $.ajax({
                type: 'get',
                url: "/index/send/agree/"+mid,
                dataType: 'json',
                success: function (data) {
                    // console.log(data);
                    if (data[0]) {
                        toastr.success('已赞');
                        // console.log(res);
                        res.html(  ' &nbsp; '+ data[1]);
                    } else {
                        toastr.error('最多只能赞一次哦', '不好意思哈: ');
                    }
                },
                error: function () {

                    toastr.error('AJAX 执行错误!', '警告:');
                }
            });


            //触发转发操作

        });




        //
        // $('.show-btn').click(function () {
        //     var ac_id = $(this).attr('data-id');
        //     console.log('查询ID为: ' + ac_id);
        //     //  执行查询
        //     showAjax(ac_id);
        // });

    });

</script>
<!-- //here ends scrolling icon -->

<!-- jQuery (necessary for Bootstrap's JavaScript plugins) -->
<script src="/static/index/js/bootstrap.js"></script>
</body>
</html>